package com.xbk.seckill.reservation.config;

import com.alibaba.druid.pool.DruidDataSource;
import com.xbk.seckill.common.config.JdbcConfig;
import com.xbk.seckill.common.config.MyBatisConfig;
import com.xbk.seckill.common.config.RedisConfig;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.context.annotation.*;
import org.springframework.jdbc.datasource.DataSourceTransactionManager;
import org.springframework.transaction.TransactionManager;
import org.springframework.transaction.annotation.EnableTransactionManagement;

/**
 * @author xiexu
 * @date 2025/4/24 08:34
 */
@Configuration
@MapperScan(value = {"com.xbk.seckill.reservation.infrastructure.mapper"})
@ComponentScan(value = {"com.xbk.seckill", "com.alibaba.cola"})
@PropertySource(value = {"classpath:properties/mysql.properties", "classpath:properties/mybatis.properties"})
@Import({RedisConfig.class})
@EnableTransactionManagement(proxyTargetClass = true)
@ServletComponentScan(basePackages = {"com.xbk.seckill"})
@EnableAspectJAutoProxy(proxyTargetClass = true)
public class TransactionConfig {

}
